package homework_2.college;

/**
 * @author 朱
 * @date 2019031821:17
 */
public class Unvirsity {
    public double math;
    public double english;
    public double chinese;
    public double sport;

    public Unvirsity(double math, double english, double chinese, double sport) {
        this.math = math;
        this.english = english;
        this.chinese = chinese;
        this.sport = sport;
    }
    public Unvirsity(){

    }

    public double getMath() {
        return math;
    }

    public void setMath(double math) {
        this.math = math;
    }

    public double getEnglish() {
        return english;
    }

    public void setEnglish(double english) {
        this.english = english;
    }

    public double getChinese() {
        return chinese;
    }

    public void setChinese(double chinese) {
        this.chinese = chinese;
    }

    public double getSport() {
        return sport;
    }

    public void setSport(double sport) {
        this.sport = sport;
    }
    public void enter(){
        if (math+english+chinese>=180&&sport>=60){
            System.out.println("恭喜！4门课总分为："+(math+english+chinese)+"且体育达标，达到大学录取线");
        }else {
            System.out.println("您落榜了！");
        }
    }
}
